<template>
  <div>
    <div>{{str}}</div>
     <br>
     <br>
     
     <button @click="fn">逆转</button>
   </div>
</template>
 
<script>
export default {
  
  data() {
    return {  str:'Hello,World'};
  },
 
  methods: {
    fn() { 
      this.str=this.str.split('').reverse().join('')
    }
  }
};
</script>

<style scoped>
     
</style>